package com.example.testrecorder.domain;

import org.litepal.annotation.Column;
import org.litepal.crud.LitePalSupport;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;

/**
 * @author Yingyong Lao
 * 创建时间 2021/5/22 19:30
 * @version 1.0
 */
public class User extends LitePalSupport {
    private int id;
    @Column(unique = true, defaultValue = "unknown")
    private String userName;

    @Column(nullable = false)
    private String password;

    private String trueName;

    @Column(unique = true)
    private String tel;

    private int age;

    private String gender;

    private String email;

    private Date registerDate;//注册时间

    private String headPortraitStr;//用户头像的存储路径

    //密保问题列表，用户和密保问题是一对多的关系，此处就是将两张表关联起来，LitePal会自动帮我们生成外键
    private List<QueAndAns> queAndAnsList=new ArrayList<>();

    private List<Issue> issueList=new ArrayList<>();


    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getTrueName() {
        return trueName;
    }

    public void setTrueName(String trueName) {
        this.trueName = trueName;
    }

    public String getTel() {
        return tel;
    }

    public void setTel(String tel) {
        this.tel = tel;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public String getGender() {
        return gender;
    }

    public void setGender(String gender) {
        this.gender = gender;
    }

    public Date getRegisterDate() {
        return registerDate;
    }

    public void setRegisterDate(Date registerDate) {
        this.registerDate = registerDate;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public List<QueAndAns> getQueAndAnsList() {
        return queAndAnsList;
    }

    public void setQueAndAnsList(List<QueAndAns> queAndAnsList) {
        this.queAndAnsList = queAndAnsList;
    }

    public List<Issue> getIssueList() {
        return issueList;
    }

    public void setIssueList(List<Issue> issueList) {
        this.issueList = issueList;
    }

    public String getHeadPortraitStr() {
        return headPortraitStr;
    }

    public void setHeadPortraitStr(String headPortraitStr) {
        this.headPortraitStr = headPortraitStr;
    }
}
